package com.tensquare.article.controller;

import com.mysql.jdbc.exceptions.MySQLDataException;
import org.hibernate.criterion.Example;

/**
 * Created with IDEA
 * author:zhiXiang-Chen
 * Date:2019/4/3
 * Time:18:04
 */
public class Test {
   int x = 0;
   public class Runner implements  Runnable{

       @Override
       public void run() {
           int current = 0;
           for (int i = 0; i < 4; i++) {
               current = x;
               System.out.println(current+",");
               x= current+2;
           }
       }
   }
   public static void main(String[] args) {
       new Test().go();
   }
   public void go(){
       Runner r1 = new Runner();
       new Thread(r1).start();
       new Thread(r1).start();
   }
}
